package com.thinkmore.es.search;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import lombok.ToString;
import org.elasticsearch.search.builder.SearchSourceBuilder;

@Getter
@Setter
@ToString(callSuper = true)
@NoArgsConstructor
@AllArgsConstructor
@Builder
public class SearchParam {

    private int pageSize = 20;
    //下面2个值如果传给前端，需要加密处理，最好的办法是直接在内部加密
    private String scrollId;
    private Object[] sortValues;

    private Class resultClass;
    private String requestId;
    private SearchSourceBuilder searchSourceBuilder;
    private String indexName;

    //0：QueryBuilder方式查询 1：json方式查询 3:wrapperQuery原生查询
    private int requestType = 0;
    private String requestBody;
}
